home *** CD-ROM | disk | FTP | other *** search
/ Mac Easy 2010 May / Mac Life Ubuntu.iso / casper / filesystem.squashfs / usr / share / python-support / python-rdflib / rdflib / FileInputSource.py < prev    next >
Encoding:
Python Source  |  2007-04-04  |  324 b   |  12 lines

  1. from xml.sax.xmlreader import InputSource
  2.  
  3. class FileInputSource(InputSource, object):
  4.     def __init__(self, file):
  5.         super(FileInputSource, self).__init__(`file`)
  6.         self.file = file
  7.         self.setByteStream(file)
  8.         # TODO: self.setEncoding(encoding)
  9.  
  10.     def __repr__(self):
  11.         return `self.file`
  12.